package wc.controller.buttonlisteners;

import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import wc.MallApplication;
import wc.controller.factory.ComputerStoreFactory;
import wc.model.component.Store;

public class ComputerStoreButtonListener implements ActionListener {

	@Override
	public void actionPerformed(ActionEvent e) {
		if(MallApplication.needToPlaceComponents.size() == 0) {
			System.out.println("Place your store");
			Store s = ComputerStoreFactory.getInstance().creatStore(5, 4);
			MallApplication.selectedComponent = s;
			MallApplication.needToPlaceComponents = s.getMustPlaceComponents();
		} else System.out.println("Not done placing nescecary items for the room");
	}

}
